home *** CD-ROM | disk | FTP | other *** search
/ Languguage OS 2 / Languguage OS II Version 10-94 (Knowledge Media)(1994).ISO / gnu / elispman.lha / elispman / elisp-33 (.txt) < prev    next >
GNU Info File  |  1993-05-11  |  51KB  |  786 lines

  1. This is Info file elisp, produced by Makeinfo-1.52 from the input file
  2. elisp.texi.
  3.    This file documents GNU Emacs Lisp.
  4.    This is edition 2.0 of the GNU Emacs Lisp Reference Manual, for
  5. Emacs Version 19.
  6.    Published by the Free Software Foundation, 675 Massachusetts Avenue,
  7. Cambridge, MA 02139 USA
  8.    Copyright (C) 1990, 1991, 1992 Free Software Foundation, Inc.
  9.    Permission is granted to make and distribute verbatim copies of this
  10. manual provided the copyright notice and this permission notice are
  11. preserved on all copies.
  12.    Permission is granted to copy and distribute modified versions of
  13. this manual under the conditions for verbatim copying, provided that
  14. the entire resulting derived work is distributed under the terms of a
  15. permission notice identical to this one.
  16.    Permission is granted to copy and distribute translations of this
  17. manual into another language, under the above conditions for modified
  18. versions, except that this permission notice may be stated in a
  19. translation approved by the Foundation.
  20. File: elisp,  Node: Selective Display,  Next: Overlay Arrow,  Prev: The Echo Area,  Up: Emacs Display
  21. Selective Display
  22. =================
  23.                                       "Selective display" is a class of
  24. minor modes in which specially marked lines do not appear on the
  25. screen, or in which highly indented lines do not appear.
  26.                                       The first variant, explicit
  27. selective display, is designed for use in a Lisp program.  The program
  28. controls which lines are hidden by altering the text.  Outline mode
  29. uses this variant.  In the second variant, the choice of lines to hide
  30. is made automatically based on indentation.  This variant is designed
  31. as a user-level feature.
  32.                                       The way you control explicit
  33. selective display is by replacing a newline (control-j) with a
  34. control-m.  The text which was formerly a line following that newline
  35. is now invisible.  Strictly speaking, it is temporarily no longer a
  36. line at all, since only newlines can separate lines; it is now part of
  37. the previous line.
  38.                                       Selective display does not
  39. directly affect editing commands.  For example, `C-f' (`forward-char')
  40. moves point unhesitatingly into invisible space.  However, the
  41. replacement of newline characters with carriage return characters
  42. affects some editing commands.  For example, `next-line' skips
  43. invisible lines, since it searches only for newlines.  Modes that use
  44. selective display can also define commands that take account of the
  45. newlines, or which make parts of the text visible or invisible.
  46.                                       When you write a selectively
  47. displayed buffer into a file, all the control-m's are replaced by their
  48. original newlines.  This means that when you next read in the file, it
  49. looks OK, with nothing invisible.  The selective display effect is seen
  50. only within Emacs.
  51.                                     - Variable: selective-display
  52.                                         This buffer-local variable
  53.                                         enables selective display.
  54.                                         This means that lines, or
  55.                                         portions of lines, may be made
  56.                                         invisible.
  57.                                            * If the value of
  58.                                              `selective-display' is
  59.                                              `t', then any portion of a
  60.                                              line that follows a
  61.                                              control-m is not displayed.
  62.                                            * If the value of
  63.                                              `selective-display' is a
  64.                                              positive integer, then
  65.                                              lines that start with more
  66.                                              than `selective-display'
  67.                                              columns of indentation are
  68.                                              not displayed.
  69.                                         When some portion of a buffer
  70.                                         is invisible, the vertical
  71.                                         movement commands operate as if
  72.                                         that portion did not exist,
  73.                                         allowing a single `next-line'
  74.                                         command to skip any number of
  75.                                         invisible lines.  However,
  76.                                         character movement commands
  77.                                         (such as `forward-char') do not
  78.                                         skip the invisible portion, and
  79.                                         it is possible (if tricky) to
  80.                                         insert or delete text in an
  81.                                         invisible portion.
  82.                                         In the examples below, what is
  83.                                         shown is the *display* of the
  84.                                         buffer `foo', which changes
  85.                                         with the value of
  86.                                         `selective-display'.  The
  87.                                         *contents* of the buffer do not
  88.                                         change.
  89.                                              (setq selective-display nil)
  90.                                                   => nil
  91.                                              
  92.                                              ---------- Buffer: foo ----------
  93.                                              1 on this column
  94.                                               2on this column
  95.                                                3n this column
  96.                                                3n this column
  97.                                               2on this column
  98.                                              1 on this column
  99.                                              ---------- Buffer: foo ----------
  100.                                              
  101.                                              (setq selective-display 2)
  102.                                                   => 2
  103.                                              
  104.                                              ---------- Buffer: foo ----------
  105.                                              1 on this column
  106.                                               2on this column
  107.                                               2on this column
  108.                                              1 on this column
  109.                                              ---------- Buffer: foo ----------
  110.                                     - Variable:
  111.                                    selective-display-ellipses
  112.                                         If this buffer-local variable
  113.                                         is non-`nil', then Emacs
  114.                                         displays `...' at the end of a
  115.                                         line that is followed by
  116.                                         invisible text.  This example
  117.                                         is a continuation of the
  118.                                         previous one.
  119.                                              (setq selective-display-ellipses t)
  120.                                                   => t
  121.                                              
  122.                                              ---------- Buffer: foo ----------
  123.                                              1 on this column
  124.                                               2on this column ...
  125.                                               2on this column
  126.                                              1 on this column
  127.                                              ---------- Buffer: foo ----------
  128.                                         You can use a display table to
  129.                                         substitute other text for the
  130.                                         ellipsis (`...').  *Note
  131.                                         Display Tables::.
  132. File: elisp,  Node: Overlay Arrow,  Next: Temporary Displays,  Prev: Selective Display,  Up: Emacs Display
  133. Overlay Arrow
  134. =============
  135.                                       The "overlay arrow" is useful for
  136. directing the user's attention to a particular line in a buffer.  For
  137. example, in the modes used for interface to debuggers, the overlay
  138. arrow indicates the line of code about to be executed.
  139.                                     - Variable: overlay-arrow-string
  140.                                         This variable holds the string
  141.                                         to display as an arrow, or
  142.                                         `nil' if the arrow feature is
  143.                                         not in use.
  144.                                     - Variable: overlay-arrow-position
  145.                                         This variable holds a marker
  146.                                         which indicates where to
  147.                                         display the arrow.  It should
  148.                                         point at the beginning of a
  149.                                         line.  The arrow text is
  150.                                         displayed at the beginning of
  151.                                         that line, overlaying any text
  152.                                         that would otherwise appear.
  153.                                         Since the arrow is usually
  154.                                         short, and the line usually
  155.                                         begins with indentation,
  156.                                         normally nothing significant is
  157.                                         overwritten.
  158.                                         The overlay string is displayed
  159.                                         only in the buffer which this
  160.                                         marker points into.  Thus, only
  161.                                         one buffer can have an overlay
  162.                                         arrow at any given time.
  163. File: elisp,  Node: Temporary Displays,  Next: Overlays,  Prev: Overlay Arrow,  Up: Emacs Display
  164. Temporary Displays
  165. ==================
  166.                                       Temporary displays are used by
  167. commands to put output into a buffer and then present it to the user
  168. for perusal rather than for editing.  Many of the help commands use
  169. this feature.
  170.                                     - Special Form:
  171.                                    with-output-to-temp-buffer
  172.                                              BUFFER-NAME FORMS...
  173.                                         This function executes FORMS
  174.                                         while arranging to insert any
  175.                                         output they print into the
  176.                                         buffer named BUFFER-NAME.  The
  177.                                         buffer is then shown in some
  178.                                         window for viewing, displayed
  179.                                         but not selected.
  180.                                         The string BUFFER-NAME
  181.                                         specifies the temporary buffer,
  182.                                         which need not already exist.
  183.                                         The argument must be a string,
  184.                                         not a buffer.  The buffer is
  185.                                         erased initially (with no
  186.                                         questions asked), and it is
  187.                                         marked as unmodified after
  188.                                         `with-output-to-temp-buffer'
  189.                                         exits.
  190.                                         `with-output-to-temp-buffer'
  191.                                         binds `standard-output' to the
  192.                                         temporary buffer, then it
  193.                                         evaluates the forms in FORMS.
  194.                                         Output using the Lisp output
  195.                                         functions within FORMS goes by
  196.                                         default to that buffer (but
  197.                                         screen display and messages in
  198.                                         the echo area, although output
  199.                                         in the general sense of the
  200.                                         word, are not affected).  *Note
  201.                                         Output Functions::.
  202.                                         The value of the last form in
  203.                                         FORMS is returned.
  204.                                              ---------- Buffer: foo ----------
  205.                                               This is the contents of foo.
  206.                                              ---------- Buffer: foo ----------
  207.                                              
  208.                                              (with-output-to-temp-buffer "foo"
  209.                                                  (print 20)
  210.                                                  (print standard-output))
  211.                                              => #<buffer foo>
  212.                                              
  213.                                              ---------- Buffer: foo ----------
  214.                                              20
  215.                                              
  216.                                              #<buffer foo>
  217.                                              
  218.                                              ---------- Buffer: foo ----------
  219.                                     - Variable:
  220.                                    temp-buffer-show-function
  221.                                         The value of this variable, if
  222.                                         non-`nil', is called as a
  223.                                         function to display a help
  224.                                         buffer.  This variable is used
  225.                                         by `with-output-to-temp-buffer'.
  226.                                         In Emacs versions 18 and
  227.                                         earlier, this variable was
  228.                                         called `temp-buffer-show-hook'.
  229.                                     - Function:
  230.                                              momentary-string-display
  231.                                              STRING POSITION &optional
  232.                                              CHAR MESSAGE
  233.                                         This function momentarily
  234.                                         displays STRING in the current
  235.                                         buffer at POSITION (which is a
  236.                                         character offset from the
  237.                                         beginning of the buffer).  The
  238.                                         display remains until the next
  239.                                         character is typed.
  240.                                         If the next character the user
  241.                                         types is CHAR, Emacs ignores it.
  242.                                         Otherwise, that character
  243.                                         remains buffered for subsequent
  244.                                         use as input.  Thus, typing
  245.                                         CHAR will simply remove the
  246.                                         string from the display, while
  247.                                         typing (say) `C-f' will remove
  248.                                         the string from the display and
  249.                                         later (presumably) move point
  250.                                         forward.  The argument CHAR is a
  251.                                         space by default.
  252.                                         The return value of
  253.                                         `momentary-string-display' is
  254.                                         not meaningful.
  255.                                         If MESSAGE is non-`nil', it is
  256.                                         displayed in the echo area
  257.                                         while STRING is displayed in
  258.                                         the buffer.  If it is `nil',
  259.                                         then instructions to type CHAR
  260.                                         are displayed there, e.g.,
  261.                                         `Type RET to continue editing'.
  262.                                         In this example, point is
  263.                                         initially located at the
  264.                                         beginning of the second line:
  265.                                              ---------- Buffer: foo ----------
  266.                                              This is the contents of foo.
  267.                                              -!-Second line.
  268.                                              ---------- Buffer: foo ----------
  269.                                              
  270.                                              (momentary-string-display
  271.                                                 "**** Important Message! ****" (point) ?\r
  272.                                                 "Type RET when done reading")
  273.                                              => t
  274.                                              
  275.                                              ---------- Buffer: foo ----------
  276.                                              This is the contents of foo.
  277.                                              **** Important Message! ****Second line.
  278.                                              ---------- Buffer: foo ----------
  279.                                              
  280.                                              ---------- Echo Area ----------
  281.                                              Type RET when done reading
  282.                                              ---------- Echo Area ----------
  283.                                         This function works by actually
  284.                                         changing the text in the
  285.                                         buffer.  As a result, if you
  286.                                         later undo in this buffer, you
  287.                                         will see the message come and
  288.                                         go.
  289. File: elisp,  Node: Overlays,  Next: Faces,  Prev: Temporary Displays,  Up: Emacs Display
  290. Overlays
  291. ========
  292.                                       You can use "overlays" to alter
  293. the appearance of a buffer's text on the screen.  An overlay is an
  294. object which belongs to a particular buffer, and has a specified
  295. beginning and end.  It also has properties which you can examine and
  296. set; these affect the display of the text within the overlay.
  297.                                    * Menu:
  298.                                    
  299.                                    * Overlay Properties::    How to read and set properties.
  300.                                                What properties do to the screen display.
  301.                                    * Managing Overlays::   Creating, moving, finding overlays.
  302. File: elisp,  Node: Overlay Properties,  Next: Managing Overlays,  Up: Overlays
  303. Overlay Properties
  304. ------------------
  305.                                       Overlay properties are like text
  306. properties in some respects, but the differences are more important
  307. than the similarities.  Text properties are considered a part of the
  308. text; overlays are specifically considered not to be part of the text.
  309. Thus, copying text between various buffers and strings preserves text,
  310. but does not try to preserve overlays.  Changing a buffer's text
  311. properties marks the buffer as modified, while moving an overlay or
  312. changing its properties does not.
  313.                                   `face'
  314.                                         This property controls the font
  315.                                         and color of text.  *Note
  316.                                         Faces::, for more information.
  317.                                         This feature is temporary; in
  318.                                         the future, we may replace it
  319.                                         with other ways of specifying
  320.                                         how to display text.
  321.                                   `mouse-face'
  322.                                         This property is used instead
  323.                                         of `face' when the mouse is
  324.                                         within the range of the
  325.                                         overlay.  This feature is also
  326.                                         temporary.
  327.                                   `priority'
  328.                                         This property's value (which
  329.                                         should be a nonnegative number)
  330.                                         determines the priority of the
  331.                                         overlay.  The priority matters
  332.                                         when two or more overlays cover
  333.                                         the same character and both
  334.                                         specify a face for display; the
  335.                                         one whose `priority' value is
  336.                                         larger takes priority over the
  337.                                         other, and its face attributes
  338.                                         override the face attributes of
  339.                                         the lower priority overlay.
  340.                                         Currently, all overlays take
  341.                                         priority over text properties.
  342.                                         Please avoid using negative
  343.                                         priority values, as we have not
  344.                                         yet decided just what they
  345.                                         should mean.
  346.                                   `window'
  347.                                         If the `window' property is
  348.                                         non-`nil', then the overlay
  349.                                         applies only on that window.
  350.                                   `before-string'
  351.                                         This property's value is a
  352.                                         string to add to the display at
  353.                                         the beginning of the overlay.
  354.                                         The string does not appear in
  355.                                         the buffer in any sense--only
  356.                                         on the screen.
  357.                                   `after-string'
  358.                                         This property's value is a
  359.                                         string to add to the display at
  360.                                         the end of the overlay.  The
  361.                                         string does not appear in the
  362.                                         buffer in any sense--only on
  363.                                         the screen.
  364.                                       These are the functions for
  365. reading and writing the properties of an overlay.
  366.                                     - Function: overlay-get OVERLAY PROP
  367.                                         This function returns the value
  368.                                         of property PROP recorded in
  369.                                         OVERLAY.  If OVERLAY does not
  370.                                         record any value for that
  371.                                         property, then the value is
  372.                                         `nil'.
  373.                                     - Function: overlay-put OVERLAY
  374.                                              PROP VALUE
  375.                                         This function set the value of
  376.                                         property PROP recorded in
  377.                                         OVERLAY to VALUE.  It returns
  378.                                         VALUE.
  379. File: elisp,  Node: Managing Overlays,  Prev: Overlay Properties,  Up: Overlays
  380. Managing Overlays
  381. -----------------
  382.                                     - Function: make-overlay START END
  383.                                              &optional BUFFER
  384.                                         This function creates and
  385.                                         returns an overlay which
  386.                                         belongs to BUFFER and ranges
  387.                                         from START to END.  Both START
  388.                                         and END must specify buffer
  389.                                         positions; they may be integers
  390.                                         or markers.  If BUFFER is
  391.                                         omitted, the overlay is created
  392.                                         in the current buffer.
  393.                                         The return value is the overlay
  394.                                         itself.
  395.                                     - Function: overlay-start OVERLAY
  396.                                         This function returns the
  397.                                         position at which OVERLAY
  398.                                         starts.
  399.                                     - Function: overlay-end OVERLAY
  400.                                         This function returns the
  401.                                         position at which OVERLAY ends.
  402.                                     - Function: overlay-buffer OVERLAY
  403.                                         This function returns the
  404.                                         buffer that OVERLAY belongs to.
  405.                                     - Function: delete-overlay OVERLAY
  406.                                         This function deletes OVERLAY.
  407.                                         The overlay continues to exist
  408.                                         as a Lisp object, but ceases to
  409.                                         be part of the buffer it
  410.                                         belonged to, and ceases to have
  411.                                         any effect on display.
  412.                                     - Function: move-overlay OVERLAY
  413.                                              START END &optional BUFFER
  414.                                         This function moves OVERLAY to
  415.                                         BUFFER, and places its bounds
  416.                                         at START and END.  Both
  417.                                         arguments START and END must
  418.                                         specify buffer positions; they
  419.                                         may be integers or markers.  If
  420.                                         BUFFER is omitted, the overlay
  421.                                         stays in the same buffer.
  422.                                         The return value is OVERLAY.
  423.                                         This is the only valid way to
  424.                                         change the endpoints of an
  425.                                         overlay.  Do not try modifying
  426.                                         the markers in the overlay by
  427.                                         hand, as that fails to update
  428.                                         other vital data structures and
  429.                                         can cause some overlays to be
  430.                                         "lost".
  431.                                     - Function: overlays-at POS
  432.                                         This function returns a list of
  433.                                         all the overlays that contain
  434.                                         position POS in the current
  435.                                         buffer.  The list is in no
  436.                                         particular order.  An overlay
  437.                                         contains position POS if it
  438.                                         begins at or before POS, and
  439.                                         ends after POS.
  440.                                     - Function: next-overlays-change POS
  441.                                         This function returns the
  442.                                         buffer position of the next
  443.                                         beginning or end of an overlay,
  444.                                         after POS.
  445. File: elisp,  Node: Faces,  Next: Blinking,  Prev: Overlays,  Up: Emacs Display
  446. Faces
  447. =====
  448.                                       A "face" is a named collection of
  449. graphical attributes: font, foreground color, background color and
  450. optional underlining.  Faces control the display of text on the screen.
  451.                                       Each face has its own "face id
  452. number" which distinguishes faces at low levels within Emacs.  However,
  453. for most purposes, you can refer to faces in Lisp programs by their
  454. names.
  455.                                       Each face name is meaningful for
  456. all frames, and by default it has the same meaning in all frames.  But
  457. you can arrange to give a particular face name a special meaning in one
  458. frame if you wish.
  459.                                    * Menu:
  460.                                    
  461.                                    * Choosing a Face::    How Emacs decides which face to use for a character.
  462.                                    * Face Functions::    How to define and examine faces.
  463. File: elisp,  Node: Choosing a Face,  Next: Face Functions,  Up: Faces
  464. Choosing a Face for Display
  465. ---------------------------
  466.                                       Here are all the ways to specify
  467. which face to use for display of text:
  468.                                       * With defaults.  Each frame has
  469.                                         a "default face", whose id
  470.                                         number is zero, which is used
  471.                                         for all text that doesn't
  472.                                         somehow specify another face.
  473.                                       * With text properties.  A
  474.                                         character may have a `face'
  475.                                         property; if so, it's displayed
  476.                                         with that face.  If the
  477.                                         character has a `mouse-face'
  478.                                         property, that is used instead
  479.                                         of the `face' property when the
  480.                                         mouse is "near enough" to the
  481.                                         character.  *Note Special
  482.                                         Properties::.
  483.                                       * With overlays.  An overlay may
  484.                                         have `face' and `mouse-face'
  485.                                         properties too; they apply to
  486.                                         all the text covered by the
  487.                                         overlay.
  488.                                       * With special glyphs.  Each
  489.                                         glyph can specify a particular
  490.                                         face id number.  *Note Glyphs::.
  491.                                       If these various sources together
  492. specify more than one face for a particular character, Emacs merges the
  493. attributes of the various faces specified.  The attributes of the faces
  494. of special glyphs come first; then come attributes of faces from
  495. overlays, followed by those from text properties, and last the default
  496. face.
  497.                                       When multiple overlays cover one
  498. character, an overlay with higher priority overrides those with lower
  499. priority.  *Note Overlays::.
  500.                                       If an attribute such as the font
  501. or a color is not specified in any of the above ways, the frame's own
  502. font or color is used.
  503. File: elisp,  Node: Face Functions,  Prev: Choosing a Face,  Up: Faces
  504. Functions for Working with Faces
  505. --------------------------------
  506.                                       The attributes a face can specify
  507. include the font, the foreground color, the background color, and
  508. underlining.  The face can also leave these unspecified by giving the
  509. value `nil' for them.
  510.                                       Here are the primitives for
  511. creating and changing faces.
  512.                                     - Function: make-face NAME
  513.                                         This function defines a new
  514.                                         face named NAME, initially with
  515.                                         all attributes `nil'.  It does
  516.                                         nothing if there is already a
  517.                                         face named NAME.
  518.                                     - Function: face-list
  519.                                         This function returns a list of
  520.                                         all defined face names.
  521.                                     - Function: copy-face OLD-FACE
  522.                                              NEW-NAME &optional FRAME
  523.                                         This function defines a new
  524.                                         face named NEW which is a copy
  525.                                         of the existing face named OLD.
  526.                                         If there is already a face
  527.                                         named NEW, then it alters the
  528.                                         face to have the same
  529.                                         attributes as OLD.
  530.                                         If the optional argument FRAME
  531.                                         is given, this function applies
  532.                                         only to that frame.  Otherwise
  533.                                         it applies to each frame
  534.                                         individually.
  535.                                       You can modify the attributes of
  536. an existing face with the following functions.  If you specify FRAME,
  537. they affect just that frame; otherwise, they affect all frames as well
  538. as the defaults that apply to new frames.
  539.                                     - Function: set-face-foreground
  540.                                              FACE COLOR &optional FRAME
  541.                                     - Function: set-face-background
  542.                                              FACE COLOR &optional FRAME
  543.                                         These functions set the
  544.                                         foreground (respectively,
  545.                                         background) color of face FACE
  546.                                         to COLOR.  The argument COLOR
  547.                                         color should be a string, the
  548.                                         name of a color.
  549.                                     - Function: set-face-font FACE FONT
  550.                                              &optional FRAME
  551.                                         This function sets the font of
  552.                                         face FACE.  The argument FONT
  553.                                         should be a string.
  554.                                     - Function: set-face-underline-p
  555.                                              FACE UNDERLINE-P &optional
  556.                                              FRAME
  557.                                         This function sets the
  558.                                         underline attribute of face
  559.                                         FACE.
  560.                                     - Function: invert-face FACE
  561.                                              &optional FRAME
  562.                                         Swap the foreground and
  563.                                         background colors of face FACE.
  564.                                         If the face doesn't specify
  565.                                         both foreground and background,
  566.                                         then its foreground and
  567.                                         background are set to the
  568.                                         background and foreground of
  569.                                         the default face.
  570.                                       These functions examine the
  571. attributes of a face.  If you don't specify FRAME, they refer to the
  572. default data for new frames.
  573.                                     - Function: face-foreground FACE
  574.                                              &optional FRAME
  575.                                     - Function: face-background FACE
  576.                                              &optional FRAME
  577.                                         These functions return the
  578.                                         foreground (respectively,
  579.                                         background) color of face FACE.
  580.                                         The argument COLOR color
  581.                                         should be a string, the name of
  582.                                         a color.
  583.                                     - Function: face-font FACE
  584.                                              &optional FRAME
  585.                                         This function returns the name
  586.                                         of the font of face FACE.
  587.                                     - Function: face-underline-p FACE
  588.                                              &optional FRAME
  589.                                         This function returns the
  590.                                         underline attribute of face
  591.                                         FACE.
  592.                                     - Function: face-id-number FACE
  593.                                         This function returns the id
  594.                                         number of face FACE.
  595.                                     - Function: face-equal FACE1 FACE2
  596.                                              &optional FRAME
  597.                                         This returns `t' if the faces
  598.                                         FACE1 and FACE2 have the same
  599.                                         attributes for display.
  600.                                     - Function:
  601.                                    face-differs-from-default-p FACE
  602.                                              &optional FRAME
  603.                                         This returns `t' if the face
  604.                                         FACE displays differently from
  605.                                         the default face.  A face is
  606.                                         considered to be "the same" as
  607.                                         the normal face if each
  608.                                         attribute is either the same as
  609.                                         that of the default face or
  610.                                         `nil' (meaning to inherit from
  611.                                         the default).
  612. File: elisp,  Node: Blinking,  Next: Inverse Video,  Prev: Faces,  Up: Emacs Display
  613. Blinking
  614. ========
  615.                                       This section describes the
  616. mechanism by which Emacs shows a matching open parenthesis when the
  617. user inserts a close parenthesis.
  618.                                     - Variable: blink-paren-function
  619.                                         The value of this variable
  620.                                         should be a function (of no
  621.                                         arguments) to be called
  622.                                         whenever a char with close
  623.                                         parenthesis syntax is inserted.
  624.                                         The value of
  625.                                         `blink-paren-function' may be
  626.                                         `nil', in which case nothing is
  627.                                         done.
  628.                                              *Please note:* this
  629.                                              variable was named
  630.                                              `blink-paren-hook' in
  631.                                              older Emacs versions, but
  632.                                              since it is not called
  633.                                              with the standard
  634.                                              convention for hooks, it
  635.                                              was renamed to
  636.                                              `blink-paren-function' in
  637.                                              version 19.
  638.                                     - Variable: blink-matching-paren
  639.                                         If this variable is `nil', then
  640.                                         `blink-matching-open' does
  641.                                         nothing.
  642.                                     - Variable:
  643.                                    blink-matching-paren-distance
  644.                                         This variable specifies the
  645.                                         maximum distance to scan for a
  646.                                         matching parenthesis before
  647.                                         giving up.
  648.                                     - Function: blink-matching-open
  649.                                         This function is the default
  650.                                         value of
  651.                                         `blink-paren-function'.  It
  652.                                         assumes that point follows a
  653.                                         character with close
  654.                                         parenthesis syntax and moves
  655.                                         the cursor momentarily to the
  656.                                         matching opening character.  If
  657.                                         that character is not already
  658.                                         on the screen, then its context
  659.                                         is shown by displaying it in
  660.                                         the echo area.  To avoid long
  661.                                         delays, this function does not
  662.                                         search farther than
  663.                                         `blink-matching-paren-distance'
  664.                                         characters.
  665.                                         Here is an example of calling
  666.                                         this function explicitly.
  667.                                              (defun interactive-blink-matching-open ()
  668.                                                "Indicate momentarily the start of sexp before point."
  669.                                                (interactive)
  670.                                                (let ((blink-matching-paren-distance
  671.                                                       (buffer-size))
  672.                                                      (blink-matching-paren t))
  673.                                                  (blink-matching-open)))
  674. File: elisp,  Node: Inverse Video,  Next: Usual Display,  Prev: Blinking,  Up: Emacs Display
  675. Inverse Video
  676. =============
  677.                                     - User Option: inverse-video
  678.                                         This variable controls whether
  679.                                         Emacs uses inverse video for
  680.                                         all text on the screen.
  681.                                         Non-`nil' means yes, `nil'
  682.                                         means no.  The default is `nil'.
  683.                                     - User Option:
  684.                                    mode-line-inverse-video
  685.                                         This variable controls the use
  686.                                         of inverse video for mode
  687.                                         lines.  If it is non-`nil',
  688.                                         then mode lines are displayed
  689.                                         in inverse video (or another
  690.                                         suitable display mode).
  691.                                         Otherwise, mode lines are
  692.                                         displayed normal, just like the
  693.                                         rest of the screen.  The
  694.                                         default is `t'.
  695. File: elisp,  Node: Usual Display,  Next: Display Tables,  Prev: Inverse Video,  Up: Emacs Display
  696. Usual Display Conventions
  697. =========================
  698.                                       The usual display conventions
  699. define how to display each character code.  You can override these
  700. conventions by setting up a display table (*note Display Tables::.).
  701. Here are the usual display conventions:
  702.                                       * Character codes 32 through 126
  703.                                         map to glyph codes 32 through
  704.                                         126.  Normally this means they
  705.                                         display as themselves.
  706.                                       * Character code 9 is a
  707.                                         horizontal tab.  It displays as
  708.                                         whitespace up to a position
  709.                                         determined by `tab-width'.
  710.                                       * Character code 10 is a newline.
  711.                                       * All other codes in the range 0
  712.                                         through 31, and code 127,
  713.                                         display in one of two ways
  714.                                         according to the value of
  715.                                         `ctl-arrow'.  If it is is
  716.                                         non-`nil', these codes map to
  717.                                         sequences of two glyphs, where
  718.                                         the first glyph is the ASCII
  719.                                         code for `^'.  Otherwise, these
  720.                                         codes map just like the codes
  721.                                         in the range 128 to 255.
  722.                                       * Character codes 128 through 255
  723.                                         map to sequences of four
  724.                                         glyphs, where the first glyph
  725.                                         is the ASCII code for `\', and
  726.                                         the others are digit characters
  727.                                         representing the code in octal.
  728.                                       The usual display conventions
  729. apply even when there is a display table, for any character whose entry
  730. in the active display table is `nil'.  Thus, when you set up a display
  731. table, you need only specify the the characters for which you want
  732. unusual behavior.
  733.                                       These variables affect the way
  734. certain characters are displayed on the screen.  Since they change the
  735. number of columns the characters occupy, they also affect the
  736. indentation functions.
  737.                                     - User Option: ctl-arrow
  738.                                         This buffer-local variable
  739.                                         controls how control characters
  740.                                         are displayed.  If it is
  741.                                         non-`nil', they are displayed
  742.                                         as an uparrow followed by the
  743.                                         character: `^A'.  If it is
  744.                                         `nil', they are displayed as a
  745.                                         backslash followed by three
  746.                                         octal digits: `\001'.
  747.                                     - Variable: default-ctl-arrow
  748.                                         The value of this variable is
  749.                                         the default value for
  750.                                         `ctl-arrow' in buffers that do
  751.                                         not override it.  This is the
  752.                                         same as executing the following
  753.                                         expression:
  754.                                              (default-value 'ctl-arrow)
  755.                                         *Note Default Value::.
  756.                                     - User Option: tab-width
  757.                                         The value of this variable is
  758.                                         the spacing between tab stops
  759.                                         used for displaying tab
  760.                                         characters in Emacs buffers.
  761.                                         The default is 8.  Note that
  762.                                         this feature is completely
  763.                                         independent from the
  764.                                         user-settable tab stops used by
  765.                                         the command `tab-to-tab-stop'.
  766.                                         *Note Indent Tabs::.
  767. File: elisp,  Node: Display Tables,  Next: Beeping,  Prev: Usual Display,  Up: Emacs Display
  768. Display Tables
  769. ==============
  770.                                       You can use the "display table"
  771. feature to control how all 256 possible character codes display on the
  772. screen.  This is useful for displaying European languages that have
  773. letters not in the ASCII character set.
  774.                                       The display table maps each
  775. character code into a sequence of "glyphs", each glyph being an image
  776. that takes up one character position on the screen.  You can also
  777. define how to display each glyph on your terminal, using the "glyph
  778. table".
  779.                                    * Menu:
  780.                                    
  781.                                    * Display Table Format::    What a display table consists of.
  782.                                    * Active Display Table::    How Emacs selects a display table to use.
  783.                                    * Glyphs::            How to define a glyph, and what glyphs mean.
  784.                                    * ISO Latin 1::            How to use display tables
  785.                                                      to support the ISO Latin 1 character set.
  786.